package com.csun.cmny.provider.dao;

import com.csun.cmny.provider.model.domain.DmcCsunHumidistatLocation;
import com.csun.cmny.provider.model.dto.humidistat.CsunHumidistatQueryDto;
import com.csun.cmny.provider.model.vo.HumidistatReqVo;
import com.csun.cmny.provider.model.dto.propertyManagement.SelectDeviceDataDto;
import com.csun.cmny.provider.model.vo.humidistat.CsunHumidistatVo;
import com.csun.cmny.provider.model.vo.life.DmcDeviceByRoom;
import com.csun.cmny.provider.model.vo.life.lifeRoomHumidistat;
import com.csun.cmny.provider.model.vo.propertyManagement.PropertyDataVo;
import org.apache.ibatis.annotations.Param;
import tk.mybatis.mapper.common.Mapper;

import java.util.List;

public interface DmcCsunHumidistatLocationMapper extends Mapper<DmcCsunHumidistatLocation> {

    /**
     * query dmc csun humidistat and location list with page
     *
     * @param csunHumidistatQueryDto the csun humidistat query dto
     *
     * @return the list
     */
    List<CsunHumidistatVo> queryListWithPage(CsunHumidistatQueryDto csunHumidistatQueryDto);

    /**
     *
     * @param roomId
     * @return
     */
    List<Long> selectDeviceIdByRoomId(Long roomId);

    /**
     *
     * @param roomId
     * @return
     */
    List<String> selectTemperatureByRoomId(Long roomId);

    /**
     *
     * @param roomId
     * @return
     */
    List<lifeRoomHumidistat> selectHumidistatByRoomId(Long roomId);

    /**
     *
     * @param alertId
     * @return
     */
    DmcDeviceByRoom selectRoomIdByDeviceId(Long alertId);

    /*
     * @param deviceId
     * @return
    * */
    List<CsunHumidistatVo> listGatewayBindHumidistat(@Param("deviceId") Long deviceId);

    List<PropertyDataVo> selectDeviceData(SelectDeviceDataDto selectDeviceDataDto);

    /*
     * @param deviceId
     * @return
    * */
    CsunHumidistatVo get(@Param("deviceId") Long deviceId);

    /**
     * 根据房间Id查询温湿度计数据
     *
     * @param roomIdList the room id list
     *
     * @return the humidistat req vo list
     */
    List<HumidistatReqVo> queryHumidistatByRoomIds(@Param("roomIdList") List<Integer> roomIdList);

    DmcCsunHumidistatLocation selectlocationBydeviceNo(@Param("deviceNo") String deviceNo);
}